<?php

namespace App\Http\Controllers\Front;

use App\Interfaces\CategoryService;
use Illuminate\Http\Request;

use App\Http\Requests;
use App\Http\Controllers\Controller;

class CategoryController extends Controller
{

    public function index($cat_id,CategoryService $categoryService)
    {
        $cat = $categoryService->get($cat_id);

        if (!$cat||$cat->parent_id==0) abort(404);

        $chidIds = $categoryService->getChildIds($cat->parent_id);
        //dd($chidIds);



    }

}
